﻿using System;
using System.Collections;
using System.Configuration;
using System.Data;
using System.Linq;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Xml.Linq;
using System.ComponentModel;
using System.Collections.Specialized;


namespace TES.WEB.EnteRegulador.Controles
{
    /// <summary>
    /// Control que muestra los detalles de un punto del enlace
    /// </summary>
    public partial class ControlDetallesPuntoEnlace : System.Web.UI.UserControl
    {
        /// <summary>
        /// Page load del control
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        protected void Page_Load(object sender, EventArgs e)
        {
            this.DataBind();
        }
        /// <summary>
        /// DataSource del control
        /// </summary>
        [System.ComponentModel.Description("DataSource del control")]
        [System.ComponentModel.Category("Data")]
        public Object DataSource
        {
           get
            {
                return Session["dataSource"] as Object;
            }
            set
            {
                Session["dataSource"] = value;
            }
        }

        /// <summary>
        /// Estilo del control
        /// </summary>
        [System.ComponentModel.Description("Clase de estilos del control")]
        [System.ComponentModel.Category("Style")]
        public string CssClass
        {
            set
            {
                FormViewContenido.CssClass = value;
            }
        }


        
        /// <summary>
        /// Hace bind del control con el datasource
        /// </summary>
        public override void DataBind()
        {
            
            FormViewContenido.DataSource = this.DataSource;
            FormViewContenido.DataBind();
        }
    }
}